package interview.javabase.thread.future;

import java.util.concurrent.Callable;

import static java.lang.Thread.currentThread;

/**
 * @author 大硕
 * 2019-03-28 9:58 PM
 **/
public class MyCallable implements Callable<String> {

    @Override
    public String call() throws Exception {
        String value = "ready";
        System.out.println("ready to work " + currentThread().getName());
        Thread.sleep(5000);
        System.out.println("task com.study.normal.done");
        return value;
    }
}